package com.authine.cloudpivot.ext.vo;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.math.BigDecimal;


@Data
@AllArgsConstructor
@NoArgsConstructor
@ApiModel("商品物流信息VO")
public class TransportV1VO {
    @ApiModelProperty("单据类型 1:发货物流 2:退货物流")
    private Integer type;
    @ApiModelProperty("订单商品")
    private V2OrderGoodsPutVO orderGoods;
    @ApiModelProperty("单据id")
    private String objId;
    @ApiModelProperty("目标id")
    private String targetId;
    @ApiModelProperty("来源id")
    private String srcId;
    @ApiModelProperty("物流")
    private String logistics;
    @ApiModelProperty("数量")
    private BigDecimal num;
    @ApiModelProperty("运单号")
    private String waybill;
    @ApiModelProperty("客户名称")
    private String orgName;

//    public static List<TransportV1VO> toTransportV1VOs(List<TransportEntity> ts){
//        List<TransportV1VO> list =new ArrayList<>();
//        if(ts!=null&&!ts.isEmpty()){
//        ts.forEach(t->{
//            list.add(new TransportV1VO(t.getType().id,V2OrderGoodsPutVO.toV2OrderGoodsPutVO(t.getOrderGoods()),t.getObjId(),
//                    t.getTargetId(),t.getSrcId(),t.getLogistics(),t.getNum(),t.getWaybill(),t.getOrgName()));
//        });
//        }
//        return list;
//    }
}